<!DOCTYPE html>
<html lang="zh-CN">
<head xmlns:th="http://www.thymeleaf.org">
    <meta charset="utf-8"/>
    <meta name="viewport"
          content="width=device-width, initial-scale=1, minimum-scale=1, maximum-scale=1, user-scalable=no"/>
    <meta http-equiv="X-UA-Compatible" content="ie=edge"/>
    <title>卡尼奶导航系统-卡尼奶导航官方授权站</title>
    <meta name="keywords" content="卡尼奶,卡尼奶授权,卡尼奶导航,卡尼奶社区,卡尼奶论坛,免费网址导航,技术分享"/>
    <meta name="description" content="卡尼奶网址导航内容管理系统是国内开源轻导航系统程序,基于Java、Springboot开发,支持扩展,支持在线模板，目前用户使用量很大的导航程序。"/>
    <link rel="shortcut icon" type="image/x-icon" href="/include/front/image/favicon.ico"/>
    <!-- 引用css -->
    <link rel="stylesheet" href="${ctxPath}/assets/libs/layui/css/layui.css"/>
    <link rel="stylesheet" href="${ctxPath}/assets/module/admin.css?v=318"/>
    <link rel="stylesheet" href="${ctxPath}/assets/css/main.css?v=318"/>
    <!-- 引用js -->
    <script type="text/javascript" src="${ctxPath}/assets/libs/jquery/jquery-3.2.1.min.js"></script>
    <script type="text/javascript" src="${ctxPath}/assets/libs/layui/layui.js"></script>
    <script src="https://oss.maxcdn.com/html5shiv/3.7.3/html5shiv.min.js"></script>
    <script src="https://oss.maxcdn.com/respond/1.4.2/respond.min.js"></script>
</head>

<body>
<ul id="nav" class="layui-nav" lay-filter="navigation">
    <li id="index_button" class="layui-nav-item"><a href="/">首页</a></li>
    <li id="doc_button" class="layui-nav-item"><a href="http://doc.jlzichan.cn">文档</a></li>
    <li id="about_button" class="layui-nav-item"><a href="http://www.jlzichan.cn" target="_blank">论坛</a></li>
    <li id="about_button1" class="layui-nav-item" style="float: right"><a href="/admin">
        <% if(isNotEmpty(userName)){ %>
        后台管理
        <% } else {%>
        登录
        <% } %>
    </a></li>
</ul>

<div style="padding-right: 30px; padding-left: 30px; margin-right: auto; margin-left: auto; width: 80%">
    <br/>
    <fieldset class="layui-elem-field layui-field-title" style="margin-top: 30px;">
        <legend>更新日志：</legend>
    </fieldset>
    <div id="container">

        <div class="layui-bg-gray" style="margin-top: 30px; padding: 10px;">
            <div class="layui-row layui-col-space10">

                <div class="layui-card">
<!--                    <div class="layui-card-header">更新日志：</div>-->
                    <div class="layui-card-body">
                        <div class="layui-card-body dynamic-card-body mini-bar" style="height: 200px;">
                            <ul class="layui-timeline">
                                <% for(notice in notices){ %>
                                <li class="layui-timeline-item">
                                    <i class="layui-icon layui-timeline-axis"></i>
                                    <div class="layui-timeline-content layui-text">
                                        <h3 class="layui-timeline-title">${notice.createTime,dateFormat="yyyy-MM-dd"}</h3>
                                        <p>
                                            ${notice.navContent}
                                        </p>
                                    </div>
                                </li>
                                <%}%>

                                <li class="layui-timeline-item">
                                    <i class="layui-icon layui-anim layui-anim-rotate layui-anim-loop layui-timeline-axis"></i>
                                    <div class="layui-timeline-content layui-text">
                                        <div class="layui-timeline-title">更久前，请联系技术人员咨询！</div>
                                    </div>
                                </li>
                            </ul>
                        </div>
                    </div>
                </div>

                <div class="layui-card">
                    <div class="layui-card-header">授权查询</div>
                    <div class="layui-card-body">

                        <form class="layui-form layui-form-pane">

                            <div class="layui-form-item">
                                <label class="layui-form-label">链接</label>
                                <div class="layui-input-block">
                                    <input type="text" name="url" autocomplete="off" placeholder="不需要加http:// 或 https://"
                                           class="layui-input" lay-verify="required"/>
                                </div>
                            </div>

                            <div class="layui-form-item">
                                <div class="layui-input-block">
                                    <button type="submit" id="submit_button" class="layui-btn" lay-submit=""
                                            lay-filter="submit_button">查询
                                    </button>
                                </div>
                            </div>

                        </form>

                    </div>
                </div>

                <script type="text/javascript">
                    layui.use(['form'], function () {
                        var form = layui.form;

                        form.on('submit(submit_button)', function (data) {
                            var load = layer.load(0, {shade: false})
                            $.ajax({
                                type: "GET",
                                url: '/api',
                                data: {'url': data.field.url},
                                contentType: "application/json",
                                dataType: "json",
                                success: function (res) {
                                    layer.close(load);
                                    if (res.code == 0) {
                                        layer.alert(res.msg, {
                                            icon: 6
                                        });
                                    } else {
                                        layer.alert(res.msg, {
                                            icon: 5
                                        });
                                    }
                                }
                            });
                            return false;
                        });
                    });
                </script>


            </div>
        </div>
    </div>
    <br/>
    <div class="layui-bg-gray" style="padding: 10px;">
        <div class="layui-row layui-col-space10">
            <div class="layui-card">
                <div class="layui-card-header">
                    友情链接
                </div>
                <div class="layui-card-body">

                    <a href="http://www.jlzichan.cn/" target="_blank">卡尼奶官方论坛</a>

                    <a href="http://doc.jlzichan.cn/" target="_blank">卡尼奶开发文档</a>

                    <a href="http://auth.jlzichan.cn/" target="_blank">卡尼奶授权站</a>
                </div>
            </div>
        </div>
    </div>
</div>
<!-- 引用js -->


</body>

</html>